package org.autumn.threadlocal;

public class TestThreadLocal {
    public static void main(String[] args) throws InterruptedException {
        ThreadLocal<String> tl = new ThreadLocal<>();

        Thread t1 = new Thread(() -> {
            tl.set("hello");
        }, "t1");

        t1.start();
        t1.join();

        System.out.println(tl.get());
    }
}
